package com.wx.wrapper;

/**
 * @Author : 佩萁
 * Description :
 * @Create : 2023/7/11 - 11:03
 */
public class StringMethod02 {
    public static void main(String[] args) {
//        String a = "jack";//小写的ascii值更大
//        String b = "JACK";
//        System.out.println(a.compareTo(b));
//        String c = "jack";//小写的ascii值更大
//        String d = "jac";
//        System.out.println(c.compareTo(d));
        String name = "john";
        int age = 10;
        double score = 56.8575;
        char gender = '男';
        String info = "我的姓名是%s 年龄是%d,成绩是%.2f,性别是%c。希望大家喜欢我！";
        String info2 = String.format(info,name,age,score,gender);
        System.out.println(info2);
    }
}
